﻿@using (Html.BeginRouteForm(new { controller = "Account", action = "table" }))
{

    if (ViewBag.check1 != "ok")
    {
       <table>
            <tr>
                <td>
                    Tài Khoản:
                </td>
                <td>
                    <input type="text" id="UserName" name="UserName" style="width: 125px" />
                </td>
            </tr>
            <tr>
                <td>
                    PassWord :
                </td>
                <td>
                    <input type="password" id="PassWord" name="PassWord" style="width: 125px" />
                </td>
            </tr>
            <tr>
                <td>
                    <button type="submit" style="width: 100px" onclick="MyFc()">
                        Đăng Nhập
                    </button>
                </td>
                <td>
                    <button type="button" style="width: 100px" onclick="MyFc()">
                        Đăng Ký
                    </button>
                    <script>
                        function MyFc() {
                            window.location = "/Account/Register";
                        }
                    </script>
                </td>
                <td>                   
                </td>
            </tr>
        </table>
                             
    }
    else
    {
         <td>
                        xin chào @ViewBag.username 
                        <li> @Html.ActionLink("Thoát", "Logoff", "Account") </li>
                        <script type="text/javascript">
                            window.location = "/Account/Profile";
                      </script> 
         </td>
    } 
}
